home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat3 / il / ilViewCallback.z / ilViewCallback
Encoding:
Text File  |  2002-10-03  |  16.7 KB  |  397 lines

  1.  
  2.  
  3.  
  4. iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))  IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll  iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk,,,, iiiillllVVVViiiieeeewwwwCCCCbbbbAAAArrrrgggg - argument passed to ilView callbacks
  10.  
  11. IIIINNNNHHHHEEEERRRRIIIITTTTSSSS FFFFRRRROOOOMMMM
  12.      ilLinkItem
  13.  
  14. HHHHEEEEAAAADDDDEEEERRRR FFFFIIIILLLLEEEE
  15.      #include <il/ilViewCallback.h>
  16.  
  17. CCCCLLLLAAAASSSSSSSS DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  18.      This class encapsulates the information passed to an iiiillllVVVViiiieeeewwww callback.  It
  19.      represents the state of the ilView when its callback function is called
  20.      and provides the ability to query various view attributes. Note that an
  21.      ilViewCbArg is passed to callback functions and cannot be directly
  22.      created.
  23.  
  24.      An ilView callback may be derived from iiiillllVVVViiiieeeewwwwMMMMeeeetttthhhhooooddddCCCCaaaallllllllbbbbaaaacccckkkk or
  25.      iiiillllVVVViiiieeeewwwwFFFFuuuunnnnccccttttiiiioooonnnnCCCCaaaallllllllbbbbaaaacccckkkk, similar to ilCallback. In both cases, an
  26.      iiiillllVVVViiiieeeewwwwCCCCbbbbAAAArrrrgggg is passed to the callback function to provide access to
  27.      ilView state information.
  28.  
  29. CCCCLLLLAAAASSSSSSSS MMMMEEEEMMMMBBBBEEEERRRR FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN SSSSUUUUMMMMMMMMAAAARRRRYYYY
  30.      CCCCoooonnnnssssttttrrrruuuuccccttttoooorrrrssss
  31.  
  32.           ilViewMethodCallback(UserClass* object,
  33.                          ilStatus (UserClass::*method)(UserArgType userArg,
  34.                                               ilViewCbArg* callerArg),
  35.                          UserArgType userArg)
  36.  
  37.           ilViewFunctionCallback(ilStatus (*func)(UserArgType userArg,
  38.                                       ilViewCbArg* callerArg),
  39.                            UserArgType userArg)
  40.  
  41.      DDDDiiiissssppppllllaaaayyyy qqqquuuueeeerrrryyyy mmmmeeeetttthhhhooooddddssss
  42.  
  43.           ilDisplay* getDisplay()
  44.           Display* getILXDisplay()
  45.           Display* getXDisplay()
  46.  
  47.      VVVViiiieeeewwww qqqquuuueeeerrrryyyy mmmmeeeetttthhhhooooddddssss
  48.  
  49.           void copyBorderList(ilIndexableList& bList)  _p_r_o_t_e_c_t_e_d
  50.           void getBorders(iflTile2Dint& top, iflTile2Dint& bot,
  51.                           iflTile2Dint& lf, iflTile2Dint& rt,
  52.                           iflOrientation orientation)
  53.           void getDel(iflXYint& dVPos, iflXYint& dVSize, iflXYZfloat& dIPos,
  54.                       iflOrientation workOrientation=iflOrientation(0))
  55.           void getImgPos(float& x, float& y)
  56.           void getNewViewTile(iflTile2D<int>& tile)
  57.           void getOldViewTile(iflTile2D<int>& tile)
  58.           int getState()
  59.           ilView* getView()
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))  IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll  iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))
  71.  
  72.  
  73.  
  74.           void getViewPos(int& x, int& y)
  75.           void getViewSize(int& nx, int& ny)
  76.           int viewExposed()
  77.           int viewMoved()
  78.           int viewResized()
  79.           int imgMoved()
  80.           int viewBorders()
  81.  
  82.      VVVViiiieeeewwww ccccoooooooorrrrddddiiiinnnnaaaatttteeee mmmmaaaappppppppiiiinnnngggg
  83.  
  84.           iflOrientation getEventOrientation()
  85.           iflOrientation getWorkOrientation()
  86.           void mapTile(iflTile2Dint& tile, iflOrientation workOrientation=iflOrientation(0))
  87.           void mapTile(iflTile2Dfloat& tile, iflOrientation workOrientation=iflOrientation(0))
  88.           void mapXY(int& x, int& y, iflOrientation workOrientation=iflOrientation(0))
  89.           void mapXY(float& x, float& y, iflOrientation workOrientation=iflOrientation(0))
  90.  
  91.  
  92. FFFFUUUUNNNNCCCCTTTTIIIIOOOONNNN DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNNSSSS
  93.      iiiillllVVVViiiieeeewwwwFFFFuuuunnnnccccttttiiiioooonnnnCCCCaaaallllllllbbbbaaaacccckkkk(((())))
  94.  
  95.           ilViewFunctionCallback(ilStatus (*func)(UserArgType userArg,
  96.                                       ilViewCbArg* callerArg),
  97.                            UserArgType userArg)
  98.  
  99.  
  100.  
  101.           This constructor creates a callback to function, _f_u_n_c, with user
  102.           argument, _u_s_e_r_A_r_g and caller argument _c_a_l_l_e_r_A_r_g.  The caller
  103.           argument is a pointer to iiiillllVVVViiiieeeewwwwCCCCbbbbAAAArrrrgggg which is described within this
  104.           man page.  iiiillllVVVViiiieeeewwwwMMMMeeeetttthhhhooooddddCCCCaaaallllllllbbbbaaaacccckkkk(((())))
  105.  
  106.           ilViewMethodCallback(UserClass* object,
  107.                          ilStatus (UserClass::*method)(UserArgType userArg,
  108.                                               ilViewCbArg* callerArg),
  109.                          UserArgType userArg)
  110.  
  111.  
  112.  
  113.           This constructor creates a callback to _U_s_e_r_C_l_a_s_s::_m_e_t_h_o_d, with user
  114.           argument, _u_s_e_r_A_r_g and caller argument _c_a_l_l_e_r_A_r_g.  The caller
  115.           argument is a pointer to iiiillllVVVViiiieeeewwwwCCCCbbbbAAAArrrrgggg which is described within this
  116.           man page.
  117.  
  118.      ccccooooppppyyyyBBBBoooorrrrddddeeeerrrrLLLLiiiisssstttt(((())))                        _p_r_o_t_e_c_t_e_d
  119.  
  120.           void copyBorderList(ilIndexableList& bList)
  121.  
  122.  
  123.           Copies list of border tiles from _b_L_i_s_t into ilViewCbArg's
  124.           borderList.  This is typically called by ilView in preparation for
  125.           invoking a callback.
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))  IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll  iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))
  137.  
  138.  
  139.  
  140.      ggggeeeettttBBBBoooorrrrddddeeeerrrrssss(((())))
  141.  
  142.           void getBorders(iflTile2Dint& top, iflTile2Dint& bot,
  143.                           iflTile2Dint& lf, iflTile2Dint& rt,
  144.                           iflOrientation orientation)
  145.  
  146.  
  147.           Returns the top, bottom, left and right tiles that describe the
  148.           unclipped border around an ilView in ttttoooopppp, bbbbooootttt, llllffff and rrrrtttt. The tiles
  149.           are mapped to the iiiiffffllllOOOOrrrriiiieeeennnnttttaaaattttiiiioooonnnn passed in _o_r_i_e_n_t_a_t_i_o_n.  Note that
  150.           if a view is partially obscured by another, the border may be broken
  151.           into several sections. See ggggeeeettttBBBBoooorrrrddddeeeerrrrLLLLiiiisssstttt().
  152.  
  153.      ggggeeeettttDDDDeeeellll(((())))
  154.  
  155.           void getDel(iflXYint& dVPos, iflXYint& dVSize, iflXYZfloat& dIPos,
  156.                       iflOrientation workOrientation=iflOrientation(0))
  157.  
  158.  
  159.           Returns the delta, or change, for the view's position, size and
  160.           image position in _d_V_P_o_s, _d_V_S_i_z_e and _d_I_P_o_s respectively. The deltas
  161.           are returned relative to the specified orientation. By default, the
  162.           deltas are returned relative to the view's work orientation which is
  163.           upper-left.  See iiiillllVVVViiiieeeewwww.
  164.  
  165.      ggggeeeettttDDDDiiiissssppppllllaaaayyyy(((())))
  166.  
  167.           ilDisplay* getDisplay()
  168.  
  169.  
  170.           Returns a pointer to the iiiillllDDDDiiiissssppppllllaaaayyyy that manages the view.
  171.  
  172.      ggggeeeettttEEEEvvvveeeennnnttttOOOOrrrriiiieeeennnnttttaaaattttiiiioooonnnn(((())))
  173.  
  174.           iflOrientation getEventOrientation()
  175.  
  176.  
  177.           Returns the orientation used to interpret events.
  178.  
  179.      ggggeeeettttIIIILLLLXXXXDDDDiiiissssppppllllaaaayyyy(((())))
  180.  
  181.           Display* getILXDisplay()
  182.  
  183.  
  184.           Returns a pointer to the internal X display used by IL for rendering
  185.           to the display window. It is used by the the render callback which
  186.           is called by the IL rendering thread. See ilView.
  187.  
  188.      ggggeeeettttIIIImmmmggggPPPPoooossss(((())))
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))  IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll  iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))
  203.  
  204.  
  205.  
  206.           void getImgPos(float& x, float& y)
  207.  
  208.  
  209.           Returns the image position in _x and _y. The image position is the
  210.           location of the view corner nearest the image origin. In other
  211.           words, it is the tile representing the portion of the image
  212.           displayed in the view.  See iiiillllVVVViiiieeeewwww.
  213.  
  214.      ggggeeeettttNNNNeeeewwwwVVVViiiieeeewwwwTTTTiiiilllleeee(((())))
  215.  
  216.           void getNewViewTile(iflTile2D<int>&tile)
  217.  
  218.  
  219.           Returns the tile that defines the new view location within the
  220.           display.
  221.  
  222.      ggggeeeettttOOOOllllddddVVVViiiieeeewwwwTTTTiiiilllleeee(((())))
  223.  
  224.           void getOldViewTile(iflTile2D<int>&tile)
  225.  
  226.  
  227.           Returns the tile that defines the old view location within the
  228.           display.
  229.  
  230.      ggggeeeettttSSSSttttaaaatttteeee(((())))
  231.  
  232.           int getState()
  233.  
  234.  
  235.           Returns the state of the view when the callback is called.  See
  236.           iiiillllVVVViiiieeeewwww.
  237.  
  238.      ggggeeeettttVVVViiiieeeewwww(((())))
  239.  
  240.           ilView* getView()
  241.  
  242.  
  243.           Returns a pointer to the iiiillllVVVViiiieeeewwww associated with the callback.
  244.  
  245.      ggggeeeettttVVVViiiieeeewwwwPPPPoooossss(((())))
  246.  
  247.           void getViewPos(int& x, int& y)
  248.  
  249.  
  250.           Returns the view position in _x and _y relative the work orientation
  251.           which is upper-left. See iiiillllVVVViiiieeeewwww.
  252.  
  253.      ggggeeeettttVVVViiiieeeewwwwSSSSiiiizzzzeeee(((())))
  254.  
  255.           void getViewSize(int& nx, int& ny)
  256.  
  257.  
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))  IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll  iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))
  269.  
  270.  
  271.  
  272.           Returns the view size in _n_x and _n_y when the callback was called.
  273.           See iiiillllVVVViiiieeeewwww.
  274.  
  275.      ggggeeeettttWWWWoooorrrrkkkkOOOOrrrriiiieeeennnnttttaaaattttiiiioooonnnn(((())))
  276.  
  277.           iflOrientation getWorkOrientation()
  278.  
  279.  
  280.           Returns the work orientation for the ilView. The work orientation is
  281.           used for internal computation and is the default orientation for may
  282.           member functions.
  283.  
  284.      ggggeeeettttXXXXDDDDiiiissssppppllllaaaayyyy(((())))
  285.  
  286.           Display* getXDisplay()
  287.  
  288.  
  289.           Returns a pointer to the X display associated with the display
  290.           window.
  291.  
  292.      iiiimmmmggggMMMMoooovvvveeeedddd(((())))
  293.  
  294.           int imgMoved()
  295.  
  296.  
  297.           Returns _T_r_u_e if the image within the ilView has been moved.
  298.           Otherwise it returns _F_a_l_s_e.
  299.  
  300.      mmmmaaaappppTTTTiiiilllleeee(((())))
  301.  
  302.           void mapTile(iflTile2Dfloat& tile,
  303.                        iflOrientation workOrientation=iflOrientation(0))
  304.           void mapTile(iflTile2Dint& tile,
  305.                        iflOrientation workOrientation=iflOrientation(0))
  306.  
  307.  
  308.           This overloaded member function is a convience and maps the
  309.           specified _t_i_l_e to the specified orientation. By default the tile is
  310.           mapped to the work orientation which is upper-left.
  311.  
  312.      mmmmaaaappppXXXXYYYY(((())))
  313.  
  314.           void mapXY(float& x, float& y,
  315.                      iflOrientation workOrientation=iflOrientation(0))
  316.           void mapXY(int& x, int& y,
  317.                      iflOrientation workOrientation=iflOrientation(0))
  318.  
  319.  
  320.           This overloaded member function is a convience and maps the
  321.           specified _x and _y_t_o coordinate to the specified orientation. By
  322.           default the tile is mapped to the work orientation which is upper-
  323.           left.
  324.  
  325.  
  326.  
  327.                                                                         PPPPaaaaggggeeee 5555
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))  IIIImmmmaaaaggggeeeeVVVViiiissssiiiioooonnnn LLLLiiiibbbbrrrraaaarrrryyyy CCCC++++++++ RRRReeeeffffeeeerrrreeeennnncccceeee MMMMaaaannnnuuuuaaaallll  iiiillllVVVViiiieeeewwwwCCCCaaaallllllllbbbbaaaacccckkkk((((3333))))
  335.  
  336.  
  337.  
  338.      vvvviiiieeeewwwwBBBBoooorrrrddddeeeerrrrssss(((())))
  339.  
  340.           int viewBorders()
  341.  
  342.  
  343.           Returns _T_r_u_e if the view has borders enabled. Otherwise it returns
  344.           _F_a_l_s_e.
  345.  
  346.      vvvviiiieeeewwwwEEEExxxxppppoooosssseeeedddd(((())))
  347.  
  348.           int viewExposed()
  349.  
  350.  
  351.           Returns _T_r_u_e if the ilView has been exposed. Otherwise it returns
  352.           _F_a_l_s_e.
  353.  
  354.      vvvviiiieeeewwwwMMMMoooovvvveeeedddd(((())))
  355.  
  356.           int viewMoved()
  357.  
  358.  
  359.           Returns _T_r_u_e if the ilView has been moved. Otherwise it returns
  360.           _F_a_l_s_e.
  361.  
  362.      vvvviiiieeeewwwwRRRReeeessssiiiizzzzeeeedddd(((())))
  363.  
  364.           int viewResized()
  365.  
  366.  
  367.           Returns _T_r_u_e if the ilView has been resized. Otherwise it returns
  368.           _F_a_l_s_e.
  369.  
  370. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  371.      ilCallback, ilView
  372.  
  373.  
  374.  
  375.  
  376.  
  377.  
  378.  
  379.  
  380.  
  381.  
  382.  
  383.  
  384.  
  385.  
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.                                                                         PPPPaaaaggggeeee 6666
  394.  
  395.  
  396.  
  397.